List of active orders
Retrieves the list of active orders with their statuses.
Request syntax
GET http://b2b-api.go.yandex.ru/integration/2.0/orders/active?user_id={user ID}
Request headers
Authorization: Bearer <OAuth-token>
OAuth access token. The steps to get a token are described in Getting started.
X-YaTaxi-Selected-Corp-Client-Id— client ID from the account. Required if multiple clients are available using the token.
Request parameters
The request has one required parameter:
user_id: ID of the employee whose orders should be viewed.
Response field description
The response contains the following field:
| Field | Description | Format |
|---|---|---|
items |
An array containing data about the routes. | Array of objects |
Structure of the items array element:
|
Field |
Description |
Format |
|
|
Order ID. |
String |
|
|
Order status. Possible values:
|
String |
Request example
GET http://b2b-api.go.yandex.ru/integration/2.0/orders/active?user_id=0354...3c71
...
Authorization: Bearer <OAuth-token>
X-YaTaxi-Selected-Corp-Client-Id: <client-id>
Response example
An example of a response to this request:
{ "items":
[
{
"id": "8f7...c83",
"status": "driving"
},
{
"id": "71e...05c",
"status": "transporting"
}
]
}
Response codes
A response to this request may contain the following HTTP codes:
200— request completed successfully.403:- SELECT_CLIENT_HEADER_REQUIRED: the request did not pass the header
X-YaTaxi-Selected-Corp-Client-Id(returned if more than one client is available for the token). - SELECTED_CLIENT_ACCESS_DENIED: the header
X-YaTaxi-Selected-Corp-Client-Idcontains the client's ID, which this login does not have access to.
- SELECT_CLIENT_HEADER_REQUIRED: the request did not pass the header